module.exports = function (path,data, method) {
  return new Promise((resolve, reject) => {
    console.log(data)
    wx.request({
      url: 'http://daxian.viphk.ngrok.org/api/' + path,
      method: method,
      data: {
        id:dta
      },
      header: {
        'Content-Type': 'json'
      },
      success: resolve,
      fail: function () {
        reject()
      }
    })
  })
}